/* eslint-disable */
import Vue from 'vue'
import Router from 'vue-router'

const index = resolve => { // 主页
    require.ensure(['@/iview/index/index.vue'], () => {
      resolve(require('@/iview/index/index.vue'))
    })
}

const Nav = resolve => { // 导航跟谁效果
    require.ensure(['@/iview/Nav.vue'], () => {
      resolve(require('@/iview/Nav.vue'))
    })
}

const animate = resolve => { // animate动画
    require.ensure(['@/iview/index/animate.vue'], () => {
      resolve(require('@/iview/index/animate.vue'))
    })
}

const keyBord = resolve => { // 数字键盘
    require.ensure(['@/iview/index/keyBord.vue'], () => {
      resolve(require('@/iview/index/keyBord.vue'))
    })
}

const swiper = resolve => { // swiper
    require.ensure(['@/iview/index/swiper.vue'], () => {
      resolve(require('@/iview/index/swiper.vue'))
    })
}

const passwordPay = resolve => { // 模拟键盘
    require.ensure(['@/iview/index/passwordPay.vue'], () => {
      resolve(require('@/iview/index/passwordPay.vue'))
    })
}
Vue.use(Router)

export default new Router({
    routes: [
        {
            path: '/',
            name: 'index',
            component: index,
        },
        {
            path: '/Nav',
            name: 'Nav',
            component: Nav,
        },
        {
            path: '/animate',
            name: 'animate',
            component: animate,
        },
        {
            path: '/keyBord',
            name: 'keyBord',
            component: keyBord,
        },
        {
            path: '/swiper',
            name: 'swiper',
            component: swiper,
        },
        {
            path: '/passwordPay',
            name: 'passwordPay',
            component: passwordPay,
        },
    ]
})
